package org.bonorsoft.modules.control.mapper;


import org.apache.ibatis.annotations.*;

import java.util.List;

public interface CommonMapper {
    @Insert("insert into police_photo(id, photo_path) values (#{id}, #{photo})")
    int addPhoto(String id, String photo);

    @Select("select photo_path from police_photo where id = #{id}")
    String getPhoto(String id);

    @Update("update police_photo set photo_path = #{photo} where id = #{id}")
    int updatePhoto(String id, String photo);

    void removeByIds(List<String> ids);

    @Select("select count(1) from police_photo where id = #{id}")
    int count(String id);

    @Select("select param_code from ep_sys_param_value where param_value = #{value} and param_type_code = #{type}")
    String queryValueByParam(String value, String type);

    @Deprecated
    String queryCodeByParam(@Param("table") String table, @Param("text") String text, @Param("code") String code, @Param("key") String key, @Param("param") String param);
}
